home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Linux Cubed Series 2: Applications
/
Linux Cubed Series 2 - Applications.iso
/
editors
/
emacs
/
xemacs
/
xemacs-1.006
/
xemacs-1
/
lib
/
xemacs-19.13
/
info
/
w3.info-1
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
Macintosh to JP
NeXTSTEP
RISC OS/Acorn
Shift JIS
UTF-8
Wrap
GNU Info File
|
1995-09-01
|
45.8 KB
|
1,098 lines
This is Info file ../info/w3.info, produced by Makeinfo-1.63 from the
input file w3.texi.
This file documents the Emacs-w3 World Wide Web browser.
Copyright (C) 1993, 1994, 1995 William M. Perry
Permission is granted to make and distribute verbatim copies of this
manual provided the copyright notice and this permission notice are
preserved on all copies.
File: w3.info, Node: Top, Next: Introduction, Up: (DIR)
This manual documents the Emacs-w3 World Wide Web browser, a Lisp
program which runs as a subsystem under Emacs. The manual is divided
into the following chapters.
* Menu:
* Introduction:: What exactly is Emacs-w3?
* Setting Up:: How to set up and install Emacs-w3.
* Basic Usage:: Basic movement and usage of Emacs-w3.
* Compatibility:: Explanation of how Emacs-w3 is compatible
with Mosaic/X and/or Netscape/X
* Controlling Formatting:: How to control how Emacs-w3 formats HTML
* HTTP/1.0 Support:: A detailed explanation of the HTTP/1.0
and MIME support in Emacs-w3.
* Security:: Various forms of security in Emacs-w3.
* Non-Unix Operating Systems:: Special considerations necessary to get
Emacs-w3 to run correctly under non-unix
OS's.
* Advanced Features:: Some of the more arcane features.
* More Help:: How to get more help--mailing lists,
newsgroups, etc.
* Future Directions:: What is planned for future revisions
of Emacs-w3
* Programming Interface:: How to use emacs-w3 from other emacs
programs.
Indices:
* Concept Index:: Concept Index
* Key Index:: Menus of command keys and their references
* Command Index:: Menus of commands and their references
* Variable Index:: Menus of variables and their references
File: w3.info, Node: Introduction, Next: Setting Up, Prev: Top, Up: Top
Introduction
************
Emacs-w3 is an Emacs subsystem that allows the user to browse the
wonderful World Wide Web.
The World Wide Web was started at the CERN physics institute in
Switzerland in 1991. The project was initially started by Tim
Berners-Lee (timbl@w3.org) for distributing data between different
research groups effectively.
The Web has since grown into the most advanced information system
currently on the internet. It is now a global hypertext system with
servers and "browsers" (programs written to interpret the hypertext
language and display it correctly, and allow the user to follow links)
exist for all major platforms (VMS, Windows, DOS, Unix, VM, NeXTstep,
Amiga, and Macintosh).
The basic concepts used in the Web are hypertext and hypermedia.
Hypertext is the same as regular text, with one exception--it can
contain links (cross-references) to other textual documents. Hypermedia
is slightly different--it can contain links to other forms of media
(movies, sounds, interactive programs, etc.).
WWW also allows searches of indices that are located anywhere on the
network; in this respect, it mirrors certain capabilities found in both
WAIS and Gopher.
---------------
CLIENT SIDE VIEW
---------------
The WWW world consists of documents and links. Indexes are special
documents which, rather than being read, may be searched. The result of
such a search is another virtual document containing links to the
documents found. A simple protocol, HTTP is used to allow a browser
program to request a keyword search by a remote information server.
The web contains documents in many formats. Those documents which
are hypertext, (real or virtual) contain links to other documents, or
places within documents. All documents, whether real, virtual or
indexes, look similar to the reader and are contained within the same
addressing scheme.
------------------------
INFORMATION PROVIDER VIEW
------------------------
WWW browsers can access many existing data systems via existing
protocols (FTP, NNTP) or via HTTP and a gateway. In this way, the
critical mass of data is quickly exceeded, and the increasing use of the
system by readers and information suppliers encourage each other.
Providing information is as simple as running the WWW server and
pointing it at an existing directory structure. The server
automatically generates the a hypertext view of the files to guide the
user around.
To personalize it, a few SGML hypertext files can be written to give
an even more friendly view. Also, any file available by anonymous FTP,
or any internet newsgroup can be immediately linked into the web. The
very small start-up effort is designed to allow small contributions. At
the other end of the scale, large information providers may provide an
HTTP server with full text or keyword indexing. This may allow access
to a large existing database without changing the way that database is
managed. Such gateways have already been made into Oracle(tm), WAIS,
and Digital's VMS/Help systems, to name but a few.
The WWW model gets over the frustrating incompatibilities of data
format between suppliers and reader by allowing negotiation of format
between a smart browser and a smart server. This should provide a
basis for extension into multimedia, and allow those who share
application standards to make full use of them across the web.
Here is some more specific information about what Emacs-w3 does and
does not understand:
* Menu:
* Markup Languages Supported:: The different markup languages that
Emacs-w3 understands natively.
* Supported Protocols:: The different network protocols that
Emacs-w3 speaks to.
File: w3.info, Node: Markup Languages Supported, Next: Supported Protocols, Prev: Introduction, Up: Introduction
Supported Markup Languages
**************************
Several different markup languages, and various extensions to those
languages, are supported by Emacs-w3.
---------
HTML 2.0
---------
HTML is composed of a set of elements that define a document and
guide its display. An HTML element may include a name, some attributes
and some text or hypertext, and appears in an HTML document as
<tag_name>text</tag_name>, <tag_name
attribute_name=argument>text</tag_name>, or just <tag_name>.
For example: `<title> My Useful Document </title>', and `<pre
width=60> A lot of text here. </pre>'.
An HTML document is composed of a single element: <html>...</html>,
that is, in turn, composed of head and body elements: <head>...</head>,
and <body>...</body>. To allow older HTML documents to remain readable,
<html>, <head>, and <body> are actually optional within HTML documents.
All the tags and attributes of HTML are fully supported in Emacs-w3.
The full HTML 2.0 specification is available via the web at
http://www.hal.com/users/connolly/html-spec/HTML_TOC.html, or via
anonymous ftp to www.ics.uci.edu:/pub/ietf/html/.
---------
HTML 3.0
---------
The HTML 3.0 language is an extension of HTML, with a large degree of
backwards compatibility with HTML 2.0. The latest revision of HTML 3.0
can be retrieved via anonymous ftp to ftp.w3.org, the file is
/www/arena/html3-dtd.txt. The following HTML 3.0 language elements are
supported by Emacs-w3:
* ID tags for headers and paragraphs. This makes it possible to
reference points within a document and not require empty hypertext
links to do it.
* Named BASE tags. Base tags allow you to specify how relative links
within a document should be resolved (typically with a different
URL than that which was used to retrieve the file). This is
useful if you want to store the file on disk, but still have the
links work correctly.
HTML 3.0 extends the power of the BASE tag by allowing multiple
BASE tags in a single document, each with a NAME or ID attribute.
Any other tag required either the HREF or SRC attribute can also
have the BASE attribute. If this matches the NAME/ID of a BASE
tag, then that URL is used as the basis for resolving the relative
link. If no base tag matches the, a base tag with no NAME/ID is
used. If no such base tag exists, the URL of the document is
used.
* Text alignment. Most tags that cause a line break (BR, H?, P,
etc) can now take an optional ALIGN attribute, which specifies how
the text enclosed within it is to be aligned. Valid alignments
are:
left
The default alignment, causes text to be flush left, with a
ragged right edge.
right
Causes text to be flush right, with a ragged left margin.
center
Causes text to be centered between the left and right margins
(this can be affected by list indentation, blockquotes, and a
few other tags).
justify
Causes text to be fully justified (both right and left margins
smooth).
indent
Causes text to be indented from the left margin.
* Limited font selection. Using the <big> and <small> tags, HTML 3.0
gives the user some control over font size without the overhead of
a stylesheet.*Note Style Sheets::
* Subscripts and superscripts. The <sub> and <sup> tags allow you to
have limited math markup anywhere in your document.
* More powerful inlined images. With the <fig> tag, you now have
much more control over inlined image formatting. Chief among them
in usefulness for Emacs-w3 users is the ability to put the old
<img> tag's alt text before the </fig> element, and the ability to
include markup in it. For example: `<fig ismap
src="fancyhrule.gif"><hr></fig>', so that the user with inlined
images turned off will get the same effect.
* Better control over list formatting. For odered (<OL>) lists, you
can now specify the type of numbering to use. With the new 'type'
attribute, you can specify arabic, alphabetical, or roman
numbering, in either upper or lowercase. Also, the optional
'start' attribute lets you specify the starting list item number.
For unordered lists (<UL>), you can specify that the browser
should not insert any bullets on list items by using the new PLAIN
attribute.
* More form widgets. New input types include RANGE, FILE, images,
and named submit and reset buttons.
* LINK support. LINKs allow the author to specify the relevance
between documents easily. This makes it possible to point to
dictionaries, glossaries, abd indices, or to specify the author of
a document.
* Annotations. Can have <footnote> and <margin> notes that show up
as footnotes at the bottom of a document.
* Notes and admonishments. The NOTE tag provides a way to specify a
warning or other standard information. Shows appropriate bitmap if
possible. Similar to warning dialogs in Windows/Macintosh.
Syntax is `<note role=simple|note|caution|warning>A note for the
user</note>'. The default role is 'simple'.
* Infinitely nested lists, and use of paragraphs and headers within
lists.
---------
Netscape-HTML
---------
I hate to say it, but I broke down and actually included some of the
netscape extensions into Emacs-w3.
<font>...</font>
You can change the font size. Valid values range from 0-7. The
default font size is 3. The value given can optionally have a '+'
or '-' character in front of it to specify that it is relative to
the document basefont.
<center>...</center>
This ugly, ill-thought-out alternative to the HTML 3.0 align
attribute on headers and paragraphs was included for
compatibility, and as an example of how not to do things.
<isindex>
The isindex tag can now take a prompt attribute, to get rid of the
default 'This is a searchable index' label.
<hr width=xx align=xx>
You can now control the width of a horizontal rule, in relation to
the total window size. The WIDTH attribute specifies how wide the
rule should be, as a percentage of the window width.
The ALIGN attribute specifies where the horizontal rule is placed.
Valid values are left, right, center, and indent.
<body background=URL bgcolor=RGB TEXT=RGB LINK=RGB VLINK=RGB>
You can specify various colors and formatting issues on a document
wide basis. This is done with various attributes on the BODY tag.
Stylesheets are really a better way to do this, and are
recommended. This is just for compatibility. *Note Style Sheets::
BACKGROUND=URL
Specifies a graphic to tile in the background of the
document. This only works in XEmacs 19.12.
BGCOLOR=COLOR
Specifies the background of the document, as a color instead
of a graphic. COLOR should be either an RGB specification
(like `"#FF00BB"'), or a logical color name (like
`"PaleGoldenrod"'). The logical color names supported are
system dependent.
TEXT=COLOR
Specifies the color of text on the page. COLOR should be
either an RGB specification (like `"#FF00BB"'), or a logical
color name (like `"PaleGoldenrod"'). The logical color names
supported are system dependent.
LINK=COLOR
Specifies the color of hypertext links on the page. COLOR
should be either an RGB specification (like `"#FF00BB"'), or
a logical color name (like `"PaleGoldenrod"'). The logical
color names supported are system dependent.
VLINK=COLOR
Specifies the color of hypertext links that have been visited
already. COLOR should be either an RGB specification (like
`"#FF00BB"'), or a logical color name (like
`"PaleGoldenrod"'). The logical color names supported are
system dependent.
---------
Extras
---------
There are several different markup elements that are not officially
part of HTML or HTML 3.0 that Emacs-w3 supports. These are either
items that were dropped from HTML 3.0 after I had implemented them, or
experimental parts of HTML that should not be counted as "official" or
long lived.
* More <HR> improvements. You can add text into a horizontal rule by
using the LABEL and TEXTALIGN attributes.
<hr label="testing" textalign="right">
yields
----------------------------------------------------------testing-
<hr label="testing" textalign="center">
yields
-----------------------------testing------------------------------
<hr label="testing" textalign="left">
yields
-Testing----------------------------------------------------------
* Entity definitions within documents. This allows the author of an
HTML page to define per-document macros. Syntax is <!ENTITY TAG
"Expansion of Tag">, which replaces all occurences of &TAG; with
Expansion of Tag.
* Embedding of arbitrary objects into an HTML document. With the
<embed> tag, you can insert any document, or image. The most
entertaining use of this is with embedding MPEG movies into an
emacs buffer. This requires Lucid Emacs 19.10, or XEmacs 19.11,
as well as a slightly patched version of mpeg_play 2.0 (the patch
is available from ftp.cs.indiana.edu:/pub/elisp/w3/mpeg_patch).
* FLAME support. For truly interesting dynamic documents. This is
replaced with a random quote from Mr. Angry (see `M-x flame' for a
sample).
* The top ten tags that did not make it into netscape. These tags
were posted to the newsgroup comp.infosystems.www.misc by Laura
Lemay (lemay@netcom.com). Much thanks to her for the humor.
<wired>...</wired>
Renders the enclosed text in a suitably ugly font/color
combination. If no default has been set up by the user, this
is the default font, with red text on a yellow background.
<roach>...</roach>
When selected, the enclosed text runs and hides under the
nearest window. OR, giggles a lot and demands nachos,
depending on your definition of "roach." (the formal
definition, of course, to be determined by the Official
Honorary Internet Standards Committee For Moving Really
Slowly.)
<kill_sgml>
Should anyone foolish enough to think that HTML is still SGML
and try and run a netscape-html document through an SGML
editor, processor, or other tool, this tag causes an
immediate core dump, erases anything on your disk with "DTD"
in the name, and emails a randomly-selected insult to Tim
Pierce.
Emacs-w3 just inserts a rude comment.
<pinhead>
Inserts "zippyisms" into the enclosed text. Perfect for
those professional documents. This is sure to be a favorite
of mine!
<secret>...</secret>
In order to read the enclosed text, you have to have secret
spy decoder glasses (available direct from Mcom for a
reasonable fee). You can also read it by holding your
computer in front of a full moon during the autumn solstice.
In Emacs-w3, this displays the text using rot13 encoding.
<hype>
Causes Marc Andreesen to magically appear and grant you an
interview (whether you want one or not). Please use this tag
sparingly.
<peek>....</peek>
<poke>...</poke>
So you want more control over screen layout in HTML? Well,
here ya go.
Actually, <peek> could almost be considered useful. The
VARIABLE attribute can be used to insert the value of an
emacs variable into the current document. Things like
'Welcome to my page, <peek variable=user-mail-address>' can
be useful in freaking people out.
<yogsothoth>
Summons the elder gods to suck away your immortal soul. Or
Bill Gates, if the elder gods are busy. Unpredictable (but
amusing) results occur when the <YOGSOTHOTH> and <HYPE> tags
are used in close proximity.
<blink>...</blink>
Causes the enclosed text to .... ooops that one made it in.
File: w3.info, Node: Supported Protocols, Prev: Markup Languages Supported, Up: Introduction
Supported Protocols
*******************
Emacs-w3 supports the following protocols
Usenet News
Can either display an entire newsgroup or specific articles by
Message-ID: header. This supports a unix-style .newsrc file, so
the user does not see articles they have read using another
newsreader, but due to how news URLs work, Emacs-w3 cannot update
the users .newsrc after they have read news.
To be more in line with the other URL schemes, Emacs-w3 lets you
specify the hostname and port of an NNTP server in a news URL.
URLs of the form news://hostname:port/messageID work, but will not
work in the majority of other browsers (yet).
HTTP
Supports both the HTTP/0.9 and HTTP/1.0 protocols. Fully
MIME-compliant with regards to HTTP/1.0. *Note HTTP/1.0 Support::
Gopher
Support for all gopher types, include CSO queries.
Gopher+
Support for Gopher+ retrievals. Support for converting ASK blocks
into HTML 3.0 FORMS and submitting them back to the server.
FTP
FTP is handled by either ange-ftp or efs, the choice is up to the
individual user.
Local files
Local files are handled, and MIME content-types are derived from
the file extensions.
Telnet
Telnet is handled by running the Emacs Lisp function `telnet', or
spawning an xterm running telnet.
TN3270
TN3270 is handled by running a tn3270 program in an Emacs buffer,
or spawning an xterm running tn3270.
Mailto
Causes a mail message to be started to a specific address.
mailserver
A more powerful version of mailto, which allows the author to
specify the subject and body text of the mail message. This type
of link is never fully executed without user confirmation, because
it is possible to insert insulting or threatening (and possibly
illegal) data into the message. The mail message is displayed,
and the user must type 'yes' to send it.
X-exec
A URL can cause a local executable to be run, and its output
interpreted as if it had come from an HTTP server. This is very
useful, but is still an experimental protocol, hence the X- prefix.
SSL
SSL requires a set of patches to the Emacs C code and SSLRef 2.0,
or an external program to run in a subprocess (similar to the
`tcp.el' package that comes with GNUS. *Note SSL::
Secure HTTP
Work is in progress to add support for the Secure HTTP
specification from Enterprise Information Technologies. The
specification for SHTTP can be found on EIT's web server at
http://www.commerce.net/information/standards/drafts/shttp.txt.
File: w3.info, Node: Setting Up, Next: Retrieving Emacs-w3, Prev: Introduction, Up: Top
Setting Up
**********
This section of the manual deals with getting, compiling, and
configuring Emacs-w3.
* Menu:
* Retrieving Emacs-w3:: Retrieving Emacs-w3 via anonymous ftp
* Compiling Emacs-w3:: Compiling Emacs-w3 and its associated files
* Basic Setup:: Basic setup that everyone needs to do
* Firewalls:: How to set Emacs-w3 up to use a particular
firewall setup.
* Proxy Gateways:: Using a proxy server
File: w3.info, Node: Retrieving Emacs-w3, Next: Compiling Emacs-w3, Prev: Setting Up, Up: Setting Up
Retrieving Emacs-w3
===================
If using Lucid Emacs 19.9 or later, skip to the section on starting
Emacs-w3. Emacs-w3 comes standard with all versions of Lucid Emacs from
19.9 onwards.
Three files are required when first installing Emacs-w3. All of them
can be found via anonymous ftp to ftp.cs.indiana.edu:/pub/elisp/w3. The
files are `w3-XXX.tar.gz', where XXX is the version number of Emacs-w3
being retrieved, `icons.tar.gz', which contains approximately 50 small
icons that Emacs-w3 requires, and are available to HTML authors. The
`extras.tar.gz' file contains ange-ftp, html-mode, and nntp.
After retrieving the files, unpack them with the following commands:
`zcat w3-XXX.tar.gz | tar xvvf -', `zcat icons.tar.gz | tar xvvf -',
and `zcat extras.tar.gz | tar xvvf -'. This unpacks the distribution
into three subdirectories `w3', `icons', and `extras'. To compile and
install all the packages in the extras directory, please see the
comments at the top of each lisp file.
File: w3.info, Node: Compiling Emacs-w3, Next: Basic Setup, Prev: Retrieving Emacs-w3, Up: Setting Up
Compiling Emacs-w3
==================
To install Emacs-w3, go into the `w3' subdirectory and edit the
`Makefile'. These variables might need to be changed:
`EMACS'
This variable controls what version of Emacs is used to compile the
programs. It should be the full path to the Emacs executable on
the system. The default is to use GNU Emacs (`emacs').
`LISPDIR'
This variable controls where the lisp code is copied to when it is
installed (with `make install'). This is usually the users
personal lisp code directory (I prefer `~/lisp'). The value is run
through "expand-file-name" and then added to the load-path.
`DOTEMACS'
This variable points to the Emacs customization file, usually
`~/.emacs'.
`INFODIR'
This variable points to the local info directory (usually
`/usr/local/info'). This can be any valid directory, as long as it
is in `Info-default-directory-list' so that info-mode can find it.
`MAKEINFO'
This variables controls how the info files are built. Possible
values are `makeinfo' or `emacs -batch -q -f batch-texinfo-format'.
Once the `Makefile' has been modified, several different targets can be
built.
`make w3'
This compiles all the .el files into the much faster .elc files.
If Jamie Zawinski's optimizing byte compiler (standard in GNU
Emacs 19 and Lucid Emacs) is used, then a few compilation warnings
are displayed (not many hopefully). These can be safely ignored
as long as everything finishes compiling. This is the default
target for `make' with no arguments.
`make install'
Compiles all the .el files and copies .el and .elc files into the
directory specified by `LISPDIR'.
`make emacs'
Modifies the file specified by `DOTEMACS'. A statement modifying
the load-path variable and several autoload statements are added
to the end of the file.
`make all'
Compiles and installs the .el files, and also modify/create the
`DOTEMACS' file.
`make w3.info'
Creates the Emacs-readable info files. The info files are created
in the directory specified by `INFODIR'. The makefile variable
`MAKEINFO' determines how the info file is built.
`make w3.dvi'
Creates the printable documentation, using tex and texindex to
properly generate the indices. A `w3.dvi' file is left in the
current directory.
File: w3.info, Node: Basic Setup, Next: Firewalls, Prev: Compiling Emacs-w3, Up: Setting Up
Basic Setup
===========
There are a few variables that almost all people need to change.
`url-bad-port-list'
List of ports to warn the user about connecting to. Defaults to
just the mail and NNTP ports so a malicious HTML author cannot
spoof mail or news to other people.
`url-be-asynchronous'
Controls whether document retrievals over HTTP should be done in
the background. This allows emacs to keep working in other
windows while large downloads occur. Defaults to `nil'. This
variable is buffer-local, so use `setq-default' after loading
Emacs-w3 to globally modify it, or set it in your `~/.emacs' file.
`url-confirmation-func'
What function to use for asking yes or no functions. Possible
values are `'yes-or-no-p' or `'y-or-n-p', or any function that
takes a single argument (the prompt), and returns `t' only if a
positive answer is gotten. Defaults to `'yes-or-no-p'.
`w3-default-action'
A lisp symbol specifying what action to take for files with
extensions that are not in the `mm-mime-extensions' assoc list.
This is useful in case Emacs-w3 ever run across files with weird
extensions (.foo, .README, .READMEFIRST, etc.). In most
circumstances, this should not be required anymore.
Possible values: any lisp symbol. Should be a function that takes
no arguments. The return value does not matter, it is ignored.
Some examples are `'w3-prepare-buffer' or `'indented-text-mode'.
`w3-default-homepage'
The url to open at startup. It can be any valid URL. This
defaults to the environment variable WWW_HOME if it is not set it
in the users `.emacs' file. If WWW_HOME is undefined, then it
defaults to the hypertext documentation for Emacs-w3 at Indiana
University.
`w3-delay-image-loads'
Controls the loading of inlined images. If non-`nil', images are
not loaded. For slow network connections, this is usually set to
`t'. Defaults to `nil'.
`w3-delimit-emphasis'
Whether to use characters at the start and end of each bold/italic
region. Types of characters are specified in
`w3-style-tags-assoc'. `w3-style-tags-assoc' is an assoc list of
style names, the `cdr' of each is a cons cell. The `car' of this
cell is the string to insert at the beginning of the emphasis, and
the `cdr' is the string to insert at the end of the emphasis. The
default value is a good example.
(
(b "*" . "*")
(address "*" . "*")
(byline "_" . "_")
(cite "_" . "_")
(cmd "*" . "*")
(dfn "*" . "*")
(em "~" . "~")
(i "~" . "~")
(q "\"" . "\"")
(removed "" . "")
(s "" . "")
(strong "*" . "*")
(sub "" . "")
(sup "" . "")
(u "_" . "_")
)
`w3-delimit-links'
Controls how hypertext links are displayed. If this variable is
`eq' to `'linkname', then the link NAME or ID of the link is
inserted after the link text. If `nil', then nothing is done. If
it is non-`nil' and not `eq' to `'linkname', then [[ & ]] is
inserted around the entire text of the link. Is initially set to
be `t' iff in normal Emacs, `nil' if in Epoch or Lucid Emacs,
since links should be in different colors/fonts.
`url-global-history-file'
The global history file used by both Mosaic/X and Emacs-w3. This
file contains a list of all the URLs that have been visited. This
file is parsed at startup and used to provide URL completion.
Emacs-w3 can read and write Mosaic/X or Netscape/X style history
files, or use its own internal format (faster). The file type is
determined automatically, or prompted for if the file does not
exist.
`w3-hotlist-file'
Hotlist filename. This should be the name of a file that is
stored in NCSA's Mosaic/X or Netscape's format. It is used to
keep a listing of commonly accessed URL's without having to go
through 20 levels of menus to get to them.
`w3-personal-annotation-directory'
The directory where Emacs-w3 looks for personal annotations. This
is a directory that should hold the personal annotations stored in
a Mosaic-compatible format.
(ncsa-mosaic-personal-annotation-log-format-1)
`url-pgp/pem-entity'
The name by which the user is known to PGP and/or PEM entities.
If this not set when `w3-do-setup' is run, it defaults to
`(user-real-login-name)'@`(system-name)', which can often be wrong.
`url-personal-mail-address'
Your full email address. This is what is sent to HTTP/1.0 servers
as the FROM field. If this is not set when `w3-do-setup' is run,
then it defaults to the value of `url-pgp/pem-entity'.
`w3-right-border'
Amount of space to leave on right margin of WWW buffers. This
amount is subtracted from `(window-width)' for each new WWW buffer
and used as the new `fill-column'.
`w3-track-mouse'
Controls whether to track the mouse and message the url under the
mouse. If this is non-`nil', then a description of the hypertext
area under the mouse is shown in the minibuffer. This shows what
type of link (inlined image, form entry area, delayed image,
delayed MPEG, or hypertext reference) is under the cursor, and the
destination. This only works in Emacs-19, Lucid Emacs, or XEmacs.
`w3-use-forms-index'
Non-`nil' means translate <ISINDEX> tags into a hypertext form. A
single text entry box is drawn where the ISINDEX tag appears. If
`t', the isindex handling is the same as Mosaic for X.
`url-use-hypertext-gopher'
Controls how gopher documents are retrieved. If non-`nil', the
gopher pages are converted into HTML and parsed just like any other
page. If `nil', the requests are passed off to the `gopher.el'
package by Scott Snyder. Using the `gopher.el' package loses the
gopher+ support, and inlined searching.
`url-wais-gateway-port'
The port # of the WAIS gateway to pass all wais:// requests to.
*Note Native WAIS Support::
`url-wais-gateway-server'
The machine name where the WAIS gateway lives. *Note Native WAIS
Support::
`url-xterm-command'
Command used to start a windowed shell, similar to an xterm. This
string is passed through `format', and should expect four strings:
the title of the window, the program name to execute, and the
server and port number. The default is for xterm, which is very
unix-centric, but is the most common case.
File: w3.info, Node: Firewalls, Next: Proxy Gateways, Prev: Basic Setup, Up: Setting Up
Firewalls
=========
There are several different reasons why you may need to use the
gateway support in Emacs-w3.
1. You are behind a firewall. This is usually the case at large
corporations with paranoid system-administrators.
2. You are using TERM (1) for slip-like access to the internet.
NOTE: Emacs 19.22 has patches to enable native TERM networking, to
enable it, #define TERM in the appropriate s/*.h file for your
operating system, then change the SYSTEM_LIBS define to include
the `termnet' library that comes with the latest versions of TERM.
3. For some reason your version of Emacs can't resolve hostnames.
This happens quite often on Sun workstations and some ultrix
machines. Some C libraries do not include the hostname resolver
routines in their static libraries. If Emacs was linked
statically, this means it won't be able to get to any machines off
your local net. This is characterized by being able to reach
someplace with a raw ip number, but not its hostname
(http://129.79.254.191/ works, but http://www.cs.indiana.edu/
doesn't).
If for some reason your system administrator will not recompile
Emacs with the `-lresolv' library or dynamic linking, you need to
act as if you were behind a firewall. Another alternative is to
set the variable `url-broken-resolution' - this will use the
support in ange-ftp or EFS to use `nslookup' in a subprocess to do
all hostname resolving. See the variables `efs-nslookup-bprogram',
`efs-nslookup-on-connect', and `efs-nslookup-threshold' if you are
using EFS, or `ange-ftp-nslookup-program' if you are using
Ange-Ftp.
4. You are running Lucid Emacs 19.x and Solaris 2.x (SunOS 5.x). For
some reason, network processes under Solaris and Lucid Emacs never
get a status of `exit' or `closed'. This causes retrieval of HTTP
and gopher pages to hang indefinitely, with Emacs chewing up large
amounts of your CPU time.
NOTE: You do not need to use gateways anymore for this problem.
With the release of Lucid Emacs 19.10, this problem is fixed if you
#define FIX_SOLARIS_W3_BUG somewhere in your config.h or s/*.h
configuration file. This will be in the stock 19.11 release of
XEmacs
Emacs-w3 has support for using the gateway mechanism for certain
domains, and directly connecting to others. To use this, you must
change the value of `url-gateway-local-host-regexp'. This should be a
regular expression (2) that matches local hosts that do not require the
use of a gateway. If `nil', then all connections are made through the
gateway.
Emacs-w3 supports several methods of getting around gateways. The
variable `url-gateway-method' controls which of these methods is used.
This variable can have several values (use these as symbol names, not
strings):
"program"
Run a program in a subprocess to connect to remote hosts (examples
are itelnet(3), an expect(4) script, etc.).
"host"
This allows you to log into another local computer that has access
to the internet, and run a telnet-like program from there.
"tcp"
Masanobu UMEDA umerin@mse.kyutech.ac.jp has written a very nice
replacement for the standard networking in Emacs. This does
basically the same thing that a method of `program' does, but is
slightly more transparent to the user.
"native"
This means that Emacs-w3 should use the builtin networking code of
Emacs. This should be used only if there is no firewall, or
someone at your site has already hacked the Emacs source to get
around your firewall. Two of these need a bit more explanation
than that: If you are running a program in a subprocess to emulate a
network connection, you need to set a few extra variables. The variable
`url-gateway-telnet-program' should point to an executable that accepts
a hostname and port # as its arguments, and passes standard input to
the remote host. This can be either the full path to the executable or
just the basename. The variable `url-gateway-telnet-ready-regexp'
controls how long Emacs-w3 should wait after spawning the subprocess to
start sending to its standard input. This gets around a bug where
telnet would miss the beginning of requests becausse it did not buffer
its input before opening a connection. This should be a regular
expression to watch for that signifies the end of the setup of
`url-gateway-telnet-program'. The default should work fine for telnet.
If you are using the `host'-based gatway method, things get a bit
more complicated. This is basically my attempt to do some of the basic
stuff of expect within elisp. First off, set the variable
`url-gateway-host' to be the name of your gateway machine.
The variable `url-gateway-connect-program' controls how the host is
reached. The easiest way is to have a program that does not require a
username and password to allow you to login. The most common of these
is the "rsh" command.
If you do not have rsh, then things get very ugly. First, set the
variable `url-gateway-program-interactive' to non-`nil'. Then you need
to define the variables `url-gateway-host-username' and
`url-gateway-host-password' to be the username and password necessary
to log into the gateway machine. The regular expressions in the
variables `url-gateway-handholding-login-regexp' and
`url-gateway-handholding-password-regexp' should match the login and
password prompts on the gateway system respectively. For example:
(setq url-gateway-connect-program "telnet"
url-gateway-host-program "telnet"
url-gateway-program-interactive t
url-gateway-host-username "wmperry"
url-gateway-host-password "yeahrightkeepdreaming"
url-gateway-host "moose.cs.indiana.edu"
url-gateway-host-program-ready-regexp "Escape character is .*"
url-gateway-handholding-login-regexp "ogin:"
url-gateway-handholding-password-regexp "ord:")
This should take care of you logging into the remote system. The
variable `url-gateway-host-prompt-pattern' should contain a regular
expression that matches the shell prompt on the remote machine. This
should appear no where in the login banner/setup, or things could get
very confused.
Now you are ready to actually get off of your local network! The
variable `url-gateway-host-program-ready-regexp' should contain a
regular expression that matches the end of the setup of
`url-gateway-host-program' when it tries to make a connection to an
off-firewall machine. (Basically the same as
`url-gateway-telnet-ready-regexp'.
Now you should be all set up to get outside your local network. If
none of this makes sense, its probably my fault. Please check with your
network administrators to see if they have a program that does most of
this for you already, since somebody somewhere at your company has
probably been through something similar to this before, and would be
much more helpful/knowledgeable about your local setup than I would be.
But feel free to mail me as a last resort.
---------- Footnotes ----------
(1) TERM is a user-level protocol for emulating IP over a serial
line. More information is available at
sunsite.unc.edu:/pub/Linux/apps/comm/term
(2) Please see the full Emacs distribution for a description of
regular expressions
(3) Itelnet is a standard name for a telnet executable that is
capable of escaping the firewall. Check with your system
administrators to see if you have anything similar
(4) Expect is a scripting language that allows you to control
interactive programs (like telnet) very easily. It is available from
gatekeeper.dec.com:/pub/GNU/expect-3.24.0.tar.gz
File: w3.info, Node: Proxy Gateways, Next: Basic Usage, Prev: Firewalls, Up: Setting Up
Proxy Gateways
==============
In late January 1993, Kevin Altis and Lou Montulli proposed and
implemented a new proxy service. This service requires the use of
environment variables to specify a gateway server/port # to send
protocol requests to. Each protocol (http, wais, gopher, ftp, etc.)
can have a different gateway server. The environment variables are
PROTOCOL_proxy, where PROTOCOL is one of gopher, file, http, ftp, or
wais.
The main thing to understand about the proxy gateway is that instead
of a partial URL being sent to the HTTP server, which is what we do
today when a client talks directly to an HTTP server, a client must
send a full URL (http://..., gopher://..., ftp://...) to the proxy
gateway server, the rest of the HTTP message is the same. For gopher
and ftp, the proxy gateway server returns the data encapsulated as a
MIME content type to the client like a normal HTTP message. HTTP MIME
content types are returned for all URL requests, regardless of the
protocol type of the URL. FTP directories, Gopher directories, etc. are
returned as text/html.
File: w3.info, Node: Basic Usage, Prev: Proxy Gateways, Up: Top
Basic Usage
***********
Emacs-w3 is similar to the Info package all Emacs users hold near
and dear to their hearts (*Note Info: (info)Top, for a description of
Info). Basically, `space' and `backspace' control scrolling, and
`return' or `mouse2' follows a hypertext link. The `f' and `b' keys
maneuver around the various links on the page.
NOTE: To enter data into a form entry area, you must select it using
`return' or `mouse2' just like a hypertext link.
On non-graphic terminals (vt100, DOS, etc.), or with a graphics
terminal and old versions (18.xx) of Emacs, hypertext links are
surrounded by '[[' and ']]' by default. On a graphics terminal with
newer versions of Emacs (epoch, lucid, or FSF 19), the links are in
bold print. *Note Controlling Formatting:: for information on how to
change this, or for help on getting the highlighting to work on graphics
terminals.
There are approximately 50 keys bound to special Emacs-w3 functions.
The basic rule of thumb regarding keybindings in Emacs-w3 is that a
lowercase key takes an action on the current document, and an uppercase
key takes an action on the document pointed to by the hypertext link
under the cursor.
There are several areas that the keybindings fall into: movement,
information, action, and miscellaneous.
* Menu:
* Movement:: Moving around in a Emacs-w3 buffer
* Information:: Getting information about the Emacs-w3 document you
are viewing, and/or links within that document.
* Action:: Taking actions in a Emacs-w3 buffer (following links,
printing, etc.)
* Miscellaneous:: Miscellaneous keybindings
File: w3.info, Node: Movement, Next: Information, Prev: Basic Usage, Up: Basic Usage
Movement
========
`SPC'
Scroll downward in the buffer. With prefix arg, scroll down that
many screenfuls.
`DEL'
Scroll upward in the buffer. With prefix arg, scroll up that many
screenfuls.
`<, M-x w3-start-of-document'
Go to start of document
`>, M-x w3-end-of-document'
Go to end of document
`Shift-TAB, b, M-x w3-back-link'
Attempts to move backward one link area in the current document.
Signals an error if no previous links are found.
`H, M-x w3-show-hotlist'
A hypertext listing of the items in the hotlist is generated on
the fly, and the links can be followed normally.
`h, M-x w3-use-hotlist'
Possibly go to a link in the hotlist. A new buffer is created for
the new document.
`m, M-x w3-complete-link'
Choose a link from the current buffer and follow it. A
completing-read is done on all the links, so `space' and `TAB' can
be used for completion.
`TAB, f, n, M-x w3-forward-link'
Attempts to move forward one link area in the current document.
Signals an error if no more links are found.
File: w3.info, Node: Information, Next: Action, Prev: Movement, Up: Basic Usage
Information
===========
These functions relate information about one or more links on the
current document.
`v, M-x url-view-url'
This shows the URL of the current document in the minibuffer.
`V, M-x w3-view-this-url'
This shows the URL of the hypertext link under point in the
minibuffer. If there is not a hypertext link under point, then it
shows the type of form entry area under point. If there is no
form entry area under point, then it shows the inlined image's URL
that is under point, if any.
`i, M-x w3-document-information'
Shows miscellaneous information about the currently displayed
document. This includes the URL, the last modified date, MIME
headers, the HTTP response code, and the LINK tags found in the
document (that describe relations between this and other
documents).
`I, M-x w3-document-information-this-url'
Shows information about the URL at point. If it is an HTTP link,
the HTTP/1.0 HEAD method is used to retrieve information, and this
is what is displayed. If it is a file or an ftp link, information
about the file is shown, including whether it is a directory, who
owns it, last access, modified, and changed times, the size, and
the file type that Emacs-w3 thinks it is (text/plain, image/gif,
etc).
`s, M-x w3-source-document'
This shows the HTML source of the current document in a separate
buffer. The `buffer-name' is based on the document's URL.
`S, M-x w3-source-document-at-point'
Shows the HTML source of the hypertext link under point in a
separate buffer. The `buffer-name' is based on the document's URL.
`k, C-k, M-x w3-save-url'
This stores the current document's URL in the kill ring, and also
in the current window-system's clipboard, if possible.
`K, M-x w3-save-this-url'
Stores the URL of the document under point in the kill ring, and
also in the current window-system's clipboard, if possible.